1. Field of the Invention
The present invention relates to image processing apparatuses, image processing methods, and computer programs which process images captured by, for example, digital cameras or input by other image inputting apparatuses and, more particularly, to an image processing apparatus, an image processing method, and a computer program which automate at least part of camerawork by image processing.
Specifically, the present invention relates to an image processing apparatus, an image processing method, and a computer program which automatically determine a composition of an input image and, more particularly, to an image processing apparatus, an image processing method, and a computer program which automatically determine a composition of an input image on the basis of an area where a target object, such as a person, is shown.
2. Description of the Related Art
Cameras have a long history as means for recording visual information. In recent years, digital cameras digitizing captured images are in wide spread use instead of film cameras making exposures by using films or sensitive plates. Digital cameras store digitized images in memories and transfer the stored images to personal computers or others, which perform image processing to the transferred images and store and manage the processed images, display the images in large displays, print out the images to edit albums including the images, or paste the images as part of documents. The digital cameras have the advantages in that there is no need to develop the captured image in order to look at the image and that there is no problem of the life of films because the digital cameras do not use the films.
Basically, digital cameras have approximately the same camerawork as film cameras. A photographer focuses a film camera on a subject, adjusts the aperture or the amount of exposure, performs framing so as to form an appropriate composition including the subject, and presses the shutter of the film camera. In order to suppress camera shaking, the photographer should hold the camera steady or mount the camera to a tripod.
Such camerawork has been advanced in its automation technologies and, therefore, even an inexperienced user is unlikely to fail in shooting. For example, the automation technologies include automatic focusing, automatic exposure, camera shaking correction, and automatic shuttering. However, the assignee supposes that the automation is not sufficiently realized in terms of the framing or determination of a composition of an image that is captured.
For example, Japanese Unexamined Patent Application Publication No. 8-262519 discloses a camera with an automatic framing function. The camera automatically sets a composition in which the gazing point (subject) of a photographer is positioned in the center of an image to prevent failure in the shooting, such as part of the subject that is dropped out from the image.
Japanese Unexamined Patent Application Publication No. 9-33986 discloses a camera which is provided with rectangular display means for framing, including the framing reference point, on the optical path of a subject so that a user can easily set a composition of an image of the subject.
In actual shooting scenes, there may be cases in which obstacles intervene between a subject and a photographer. In such cases, it is necessary to determine a composition so as to include only the subject in a frame. Particularly, if such obstacles are moving, it is difficult to include the subject in the frame and to release the shutter at the right moment while avoiding the obstacles. In addition, there may be cases in which an out-of-focus image of an unnecessary object, such as a finger of a user or a strap mounted to the main body of the camera, is shown in a picture to ruin the picture although the subject is included in the frame. It is not possible to completely remove such obstacles by a method of determining a composition on the basis of the subject. Accordingly, such obstacles are likely not to be found before displaying the image and, thus, it is not possible to take a photo-opportunity again.
For example, when a user attempts to shoot desired subjects with a digital camera, the subjects that are obstructed by shadows of persons in front of the user can be recognized through the view finder of the digital camera, as shown in FIG. 14. In such a case, it is desirable that a maximum rectangular area that does not include unnecessary areas, such as shadows of persons, and that has a predetermined aspect ratio is determined to be the composition, as shown in FIG. 15. However, the user has no choice but to manually perform this complicated determination.